<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<link rel="stylesheet" type="text/css" href="view/default/style/basic.css" />
<link rel="stylesheet" type="text/css" href="view/default/style/details.css" />
<script type="text/javascript" src="view/default/js/browserdetect.js"></script>
<script type="text/javascript" src="view/default/js/ajax.js"></script>
<script type="text/javascript" src="view/default/js/details.js"></script>
<title>{$oneGoods[0]->name} -- 在线商城</title>
</head>
<body>
{include file='default/public/header.html'}
<div id="sait">
    当前位置：<a href="./">首页</a>
  {foreach from=$FrontNav[0]->sait key=key item=value}
  &gt; <a href="?a=list&navid={$key}">{$value}</a>
  {/foreach} 
  &gt; {$oneGoods[0]->name}
</div>

<div id="sidebar">
    <h2>{$FrontNav[0]->name}</h2>
    <ul style="margin:0 0 10px 0">
        {foreach from=$FrontNav[0]->child key=key item=value}
        <li><a href="?a=list&navid={$value->id}">{$value->name}(<span class="gray">{$value->count}</span>)</a></li>
        {/foreach}
    </ul>
    <h2>当月热销</h2>
    <div style="margin:0 0 10px 0">
        {foreach from=$hotGoods key=key item=value}
        <dl>
            <dt><a href="?a=details&navid={$value->nav}&goodsid={$value->id}"><img src="{$value->thumbnail}" style="width:100px;height:100px;"></a></dt>
            <dd class="price">￥{$value->price_sale}</dd>         
            <dd class="title"><a href="?a=details&navid={$value->nav}&goodsid={$value->id}">{$value->name}</a></dd>         
        </dl>
        {/foreach}
    </div>
    <h2>浏览记录</h2>
    <div style="margin:0 0 10px 0">
        {foreach from=$viewRecord key=key item=value}
        {if $key < 2}
            <dl>
                <dt><a href="?a=details&navid={$value.nav}&goodsid={$value.id}" target="_blank"><img src="{$value.thumbnail}" style="width:100px;height:100px;"></a></dt>
                <dd class="price">￥{$value.price}</dd>         
                <dd class="title"><a href="?a=details&navid={$value.nav}&goodsid={$value.name}" target="_blank">{$value.name}</a></dd>         
            </dl>
        {/if}
        {/foreach}
        <p><a href="?a=list&m=clearViewRecord">清空</a></p>
    </div>
</div>
<div id="main">
    <h2>{$oneGoods[0]->name}</h2>
    <dl class="pic">
        <dt><a href="###"><img src="{$oneGoods[0]->thumbnail}"></a></dt>
        <dd>分享至：
        <script type="text/javascript">var thumbnail = '{$domain}{$oneGoods[0]->thumbnail}';</script>
        {literal}<a href="javascript:void((function(s,d,e){try{}catch(e){}var f='http://service.weibo.com/share/share.php?',u=d.location.href,p=['url=',e(u),'&title=',e(d.title),'&pic=',e(thumbnail),'&appkey='].join('');function a(){if(!window.open([f,p].join(''),'mb',['toolbar=0,status=0,resizable=1,width=620,height=450,left=',(s.width-620)/2,',top=',(s.height-450)/2].join('')))u.href=[f,p].join('');};if(/Firefox/.test(navigator.userAgent)){setTimeout(a,0)}else{a()}})(screen,document,encodeURIComponent));">新浪微博</a> | 
        
        <script type="text/javascript">
            function postToWb(){
            var _t = encodeURI(document.title);
            var _url= encodeURIComponent(document.location);
            var _appkey= encodeURI("appkey");//你从腾讯获得的appkey
            var _pic=encodeURI(thumbnail);//（列如：var_pic='图片url1|图片url2’）
            var _site = 'http://localhost/Mall';//你的网站地址
            var _u = 'http://v.t.qq.com/share/share.php?title='+_t+'&url='+_url+'&appkey='+_appkey+'&site='+_site+'&pic='+_pic;
            window.open(_u,'转播到腾讯微博','width=700,height=680,top=0,left=0,toolbar=no,menubar=no,scrollbars=no,location=yes,resizable=no,status=no');
            }
        </script>  
        <a href="javascript:void(0)"onclick="postToWb();"class="tmblog">腾讯微博</a> |      
        <a href="javascript:void((function(s,d,e){if(/renren\.com/.test(d.location))return;var f='http://share.renren.com/share/buttonshare?link=',u=d.location,l=d.title,p=[e(u),'&title=',e(l)].join('');function a(){if(!window.open([f,p].join(''),'xnshare',['toolbar=0,status=0,resizable=1,width=626,height=436,left=',(s.width-626)/2,',top=',(s.height-436)/2].join('')))u.href=[f,p].join('');};if(/Firefox/.test(navigator.userAgent))setTimeout(a,0);else a();})(screen,document,encodeURIComponent));"title="分享到人人">人人网</a> | 
        <a href="javascript:d=document;t=d.selection?(d.selection.type!='None'?d.selection.createRange().text:''):(d.getSelection?d.getSelection():'');void(kaixin=window.open('http://www.kaixin001.com/~repaste/repaste.php?&amp;rurl='+escape(d.location.href)+'&amp;rtitle='+escape(d.title)+'&amp;rcontent='+escape(d.title),'kaixin'));kaixin.focus();">开心网</a>
        </dd>{/literal}
    </dl>
    <dl class="text" id="text">
        <form method="post" name="buy">
            <input type="hidden" id="currentPage" value="" />
            <input type="hidden" id="currentPage2" value="" />
            <input type="hidden" name="prev" value="{$pervPage}" />
            <input type="hidden" name="attrtype" id="attrtype" value="{$oneGoods[0]->attr}" />
            <input type="hidden" name="attrway" id="attrway" value="{$theWay}" />
            <input type="hidden" name="id" id="aid" value="{$oneGoods[0]->id}" />
            <input type="hidden" name="name" value="{$oneGoods[0]->name}" />
            <input type="hidden" name="sn" value="{$oneGoods[0]->sn}" />
            <input type="hidden" name="price_sale" value="{$oneGoods[0]->price_sale}" />
            <input type="hidden" name="weight" value="{$oneGoods[0]->weight}" />
            <input type="hidden" name="nav" value="{$oneGoods[0]->nav}" />
            <input type="hidden" name="thumbnail_small" value="{$oneGoods[0]->thumbnail_small}" />
            <dd>售　　价：<span class="sale">￥{$oneGoods[0]->price_sale}</span><span class="market">￥{$oneGoods[0]->price_market}</span></dd>
            <dd>商品编号：{$oneGoods[0]->sn}</dd>
            <dd>所属品牌：{$oneGoods[0]->brandName}</dd>
            <dd>当月销量：<span class="sale_num">{$oneGoods[0]->sales}</span> {$oneGoods[0]->unit}</dd>
            <dd>总  销  量：<span class="sale_num">{$oneGoods[0]->total_sales}</span> {$oneGoods[0]->unit}</dd>
            <dd>重　　量：{$oneGoods[0]->weight} kg <span class="gray">(免运费)</span></dd>
            <dd>数　　量：<input type="text" name="num" class="num" value="1" id="n" onkeyup="noMore(this);"/> (库存还剩 {$oneGoods[0]->inventory}{$oneGoods[0]->unit})</dd>
            <dd id="warning" style="color:red;display:none;">你填写的数量超过了库存!</dd>
            <dd class="buy_bn">
            {if $oneGoods[0]->is_up == 1}
            <input type="submit" name="send" value="" class="submit" id="sub" onclick="return ajaxBuy();"/>
            {else}
            <strong class="down">此商品已下架</strong>
            {/if}
            <a><img src="view/default/images/collect.gif" /></a></dd>
        </form>
    </dl>
    <div class="content">
        <a name="commend"></a>
        <ul>
            <li class="first" id="bn1" onclick="channel(1);">商品详情</li>
            <li id="bn2" onclick="channel(2);">评价列表</li>
            <li id="bn3" onclick="channel(3);">成交记录</li>
            <li id="bn4" onclick="channel(4);">售后服务</li>
        </ul>
        <div class="c1" id="c1" style="display:block;">
            
            {$oneGoods[0]->content}
        </div>
        <div class="c2" id="c2" style="display:none;">
        <div class="c2" id="content"></div>
        <div id="page"></div>
        </div>
        
        <div class="c3" id="c3" style="display:none;">
            <table border="0" cellspacing="0" width="100%" class="record" id="recordContent">
                
            </table>
        <div id="page2"></div>
        </div>
        <div class="c4" id="c4" style="display:none;">
        {$oneGoods[0]->service}
        </div>
    </div>
    <div id="tips">
        <h2>添加购物车成功!<a onclick="setClose();"><img src="view/default/images/close_icon.png" /></a></h2>
        <p>你可以选择：</p>
        <a href="?a=cart" class="checkout">去购物车结算</a> <a href="###" class="a" onclick="setClose();">再逛逛吧</a>
        <p class="ps" style="padding-top:20px;">GoForward在线商城系统 http://www.go.com</p>
        <p class="ps">CopyRight All 粤备案号：3727021</p>
    </div>
</div>
{include file='default/public/footer.html'}
</body>
</html>